﻿<%@ Page Title="" Language="C#" MasterPageFile="~/default.Master" AutoEventWireup="true" CodeBehind="CorrectItem.aspx.cs" Inherits="InstrumentCheck.WebUI.CorrectItem" %>
<%@ Register src="UserControl/UCSelectAssetNO.ascx" tagname="UCSelectAssetNO" tagprefix="uc1" %>
<%@ Register Src="~/UserControl/UCSelectEmp.ascx" TagName="UCSelectEmp" TagPrefix="uc2" %>
<%@ Register src="UserControl/UCSelectPR.ascx" tagname="UCSelectPR" tagprefix="uc3" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Body" runat="server">
<script type="text/javascript" src="js/Form.js"></script>
<script type="text/javascript" src="js/Calendar/WdatePicker.js"></script>
<table  width="800" border="1" cellspacing="0" cellpadding="0" rules="all" frame="box" style="border-style:groove;border-color:Black;">
    <tr>
        <td colspan="6" class="descData">Aopen建碁股份有限公司 / 儀校申請單</td>
    </tr>  
    <tr>                
        <td colspan="6">
            <table width="100%">
                <tr>
                    <td align="left">
                        <asp:ImageButton runat="server" ID="imgSend" ImageUrl="~/images/imgSend.png" 
                            ToolTip="傳送" Visible = "false" OnClientClick="return CheckBeforeSend();" onclick="imgSend_Click" />
                        <asp:ImageButton runat="server" ID="imgSave" ImageUrl="~/images/imgSave.png" ToolTip="草稿儲存" Visible="false" />
                        <asp:ImageButton runat="server" ID="imgAgree" ImageUrl="~/images/imgAgree.png" ToolTip="同意" Visible="false" />
                        <asp:ImageButton runat="server" ID="imgDisagree" ImageUrl="~/images/imgDisagree.gif" ToolTip="不同意" Visible="false" />
                        <asp:ImageButton runat="server" ID="imgWithDraw" ImageUrl="~/images/imgWithDraw.gif" ToolTip="撤銷" Visible="false" />
                    </td>
                    <td align="right">
                        <div id="divFlowDesc" runat="server">
                            <font color="blue">流程提示：</font>
                            <asp:Label runat="server" ID="lblFlowDesc" ForeColor="Red"></asp:Label>
                        </div>
                    </td>
                </tr>
            </table>
        </td>
    </tr> 
    <tr>
        <td class="desc">單&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 號</td>
        <td colspan="5" class="descData"><asp:Label runat="server" ID="lblFormNO" /></td>        
    </tr>
    <tr>
        <td class="desc">填 表 人</td>
        <td colspan="3" class="descData">
            <asp:label runat="server" ID="lblCreaterInfo" />
        </td>
        <td rowspan="2" class="desc">申請日期</td>
        <td rowspan="2" class="auto"><asp:Label runat="server" ID="lblApplyDate" /></td>
    </tr> 
    <tr>
        <td class="desc">申 请 人</td>
        <td class="descData">
            <asp:Label ID="lblApplicant" runat="server" />
            <img alt="Find" src="images/imgFind.png" onclick="ShowChoiceDiv('divUser',400,300)" />
            <asp:TextBox runat="server" ID="txtApplicantNO" CssClass="hide" />
        </td>
        <td class="desc">申請部門</td>
        <td class="descData"><asp:Label ID="lblApplyDept" runat="server" /></td>
    </tr>    
    <tr>
        <td class="desc">表單申請狀態</td>
        <td colspan="5" class="descData">
            <asp:CheckBox runat="server" ID="chkNew" Text="New(全新設備首次申請入系統)" OnClick="CheckBoxNewChecked(this)" /> &nbsp;&nbsp;&nbsp;&nbsp;
            <asp:CheckBox runat="server" ID="chkModify" Text="Change(送校申請，基本資料修改)" OnClick="CheckBoxChangeChecked(this)" />
        </td>
    </tr>
    <tr>
        <td class="desc">申請原因</td>
        <td colspan="5" class="descData">
            <asp:TextBox runat="server" ID="txtApplyReason" Width="99%" MaxLength="255" TextMode="MultiLine" CssClass="must" />
        </td>
    </tr>
    <tr>
        <td class="desc">資產類別</td>
        <td colspan="2" class="descData">
            <asp:DropDownList runat="server" ID="ddlAssetType" CssClass="mustDropDownList">
                <asp:ListItem Value=""></asp:ListItem>
                <asp:ListItem Value="1">固定資產</asp:ListItem>
                <asp:ListItem Value="2">列管品</asp:ListItem>
            </asp:DropDownList>
        </td>
        <td class="desc">資產編號</td>
        <td colspan="2" class="descData">
            <asp:TextBox ID="txtAssetNO" runat="server" CssClass="must" onchange="test();" />
            <img src="images/imgFind.png" alt="Find" onclick="ShowChoiceDiv('divAsset',600,400)" />
        </td>
    </tr>
    <tr>
        <td class="desc">保管部門</td>
        <td colspan="2" class="descData"><asp:Label runat="server" ID="lblKeepDept" /></td>
        <td class="desc">保&nbsp; 管&nbsp; 人</td>
        <td colspan="2" class="descData"><asp:Label runat="server" ID="lblKeeper" /></td>
    </tr>
    <tr>
        <td class="desc">品&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 名</td>
        <td colspan="2" class="descData"><asp:Label runat="server" ID="lblChiName" /></td>
        <td class="desc">廠&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 牌</td>
        <td colspan="2" class="descData"><asp:Label runat="server" ID="lblBrand" /></td>
    </tr>
    <tr>
        <td class="desc">規&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 格</td>
        <td colspan="5" class="descData"><asp:Label runat="server" ID="lblSpec" /></td>
    </tr>
    <tr>
        <td class="desc">型&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 號</td>
        <td colspan="2" class="descData">
            <asp:Label ID="lblModuleNO" runat="server" />
        </td>
        <td class="desc">PR單號</td>
        <td colspan="2" class="descData">
            <asp:TextBox runat="server" ID="txtPRNO" CssClass="must" />
            <img src="images/imgFind.png" alt="Find" onclick="ShowChoiceDiv('divPR',400,300)" />
        </td>
    </tr>
    <tr>
        <td class="desc" width="10%">購買日期</td>
        <td class="descData" width="25%"><asp:TextBox runat="server" ID="txtBuyDate" CssClass="must" onfocus="WdatePicker({skin:'whyGreen',dateFmt:'yyyy/MM/dd'})" /></td>
        <td class="desc" width="10%">幣別(1)</td>
        <td class="descData" width="15%">
            <asp:DropDownList ID="ddlBuyCurrency" runat="server">
                <asp:ListItem Value=""></asp:ListItem>
                <asp:ListItem Value="NTD">NTD</asp:ListItem>
                <asp:ListItem Value="USD">USD</asp:ListItem>
            </asp:DropDownList>
        </td>
        <td class="desc" width="15%">購買金額(1)</td>
        <td class="descData" width="20%"><asp:TextBox runat="server" ID="txtBuyAmount" /></td>
    </tr>
    <tr>
        <td class="desc">首校日期</td>
        <td class="descData"><asp:TextBox runat="server" ID="txtFirstCorrectDate" onfocus="WdatePicker({skin:'whyGreen',dateFmt:'yyyy/MM/dd'})" CssClass="must" /></td>
        <td class="desc">幣別(2)</td>
        <td class="descData">
            <asp:DropDownList ID="ddlCorrectCurrency" runat="server">
                <asp:ListItem Value=""></asp:ListItem>
                <asp:ListItem Value="NTD">NTD</asp:ListItem>
                <asp:ListItem Value="USD">USD</asp:ListItem>
            </asp:DropDownList>
        </td>
        <td class="desc">校驗費用(2)</td>
        <td class="descData"><asp:TextBox runat="server" ID="txtCorrectAmount" 
                CssClass="must" /></td>                
    </tr>
    <tr>
        <td class="desc">應校日期</td>
        <td colspan="2" class="descData"><asp:TextBox ID="txtNeedCorrectDate" onfocus="WdatePicker({skin:'whyGreen',dateFmt:'yyyy/MM/dd'})"
                runat="server" CssClass="must" /></td>
        <td class="desc">校驗週期</td>
        <td colspan="2" class="descData">
            <asp:DropDownList runat="server" ID="ddlCorrectCycle" CssClass="mustDropDownList">
                <asp:ListItem Value=""></asp:ListItem>
                <asp:ListItem Value="1">半年</asp:ListItem>
                <asp:ListItem Value="2">一年</asp:ListItem>
                <asp:ListItem Value="3">兩年</asp:ListItem>
            </asp:DropDownList>
        </td>
    </tr>
    <tr>
        <td class="desc">目前狀態</td>
        <td colspan="2" class="descData">
            <asp:DropDownList ID="ddlCurrentStatus" runat="server" CssClass="mustDropDownList">
                <asp:ListItem Value=""></asp:ListItem>
                <asp:ListItem Value="1">需校驗</asp:ListItem>
                <asp:ListItem Value="4">免驗</asp:ListItem>
                <asp:ListItem Value="5">暫停使用</asp:ListItem>
                <asp:ListItem Value="6">禁止使用</asp:ListItem>
                <asp:ListItem Value="7">報廢</asp:ListItem>
            </asp:DropDownList>
        </td>
        <td class="desc">儀器圖片</td>
        <td colspan="2" class="descData">
            <asp:Label runat="server" ID="lblCorrectPictures" Width="90%" />
            <img alt="Upload" src="images/imgAttachment.gif" onclick="ShowChoiceDiv('divImages',600,400)" />
        </td>
    </tr>
    <tr>
        <td class="desc">校驗區分</td>
        <td colspan="2" class="descData">
            <asp:DropDownList runat="server" ID="ddlCorrectType" CssClass="mustDropDownList">
                <asp:ListItem Value=""></asp:ListItem>
                <asp:ListItem Value="1">內校</asp:ListItem>
                <asp:ListItem Value="2">外校</asp:ListItem>
            </asp:DropDownList>
        </td>
        <td class="desc">附&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 件</td>
        <td colspan="2" class="descData">
            <asp:Label runat="server" ID="lblCorrectAttach" Width="90%" />
            <img alt="Upload Attachment" src="images/imgAttachment.gif" onclick="ShowChoiceDiv('divAttach',600,400)" />
        </td>
    </tr>
    <tr>
        <td class="desc">校驗結果</td>
        <td class="descData" colspan="5">
            <asp:DropDownList runat="server" ID="ddlCorrectStatus">
                <asp:ListItem Value=""></asp:ListItem>
                <asp:ListItem Value="1">合格</asp:ListItem>
                <asp:ListItem Value="2">限定使用</asp:ListItem>
                <asp:ListItem Value="0">不合格</asp:ListItem>
            </asp:DropDownList>
            <asp:TextBox ID="txtAttachInfo" runat="server" CssClass="hide"></asp:TextBox>
            <asp:TextBox ID="txtImageInfo" runat="server" CssClass="hide"></asp:TextBox>
        </td>
    </tr>
    <tr>
        <td class="desc">允收標準</td>
        <td colspan="2" class="descData">
            <asp:TextBox runat="server" ID="txtStandard" MaxLength="4000" TextMode="MultiLine" Width="98%" />
        </td>
        <td class="desc">備 註 欄</td>
        <td colspan="2" class="descData">
            <asp:TextBox runat="server" ID="txtRemark" MaxLength="4000" TextMode="MultiLine" Width="98%" />
        </td>
    </tr>
</table>
<asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>


<div id="divBack" oncontextmenu="return false" style="position:absolute;top:0px;filter:alpha(opacity=60);background-color:#777777;z-index:2;left:0px;display:none;"></div>

<div id="divAsset" align="center" style="position:absolute;z-index:3;background-color:#ffffef;display:none;">
<asp:UpdatePanel runat="server">
    <ContentTemplate>
        <uc1:UCSelectAssetNO ID="UCSelectAssetNO1" runat="server" />
    </ContentTemplate>
</asp:UpdatePanel>
</div>

<div id="divUser" style="position:absolute;z-index:3;background-color:#ffffef;display:none;text-align:center">
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>
        <uc2:UCSelectEmp ID="UCSelectEmpApplicant" runat="server" />
    </ContentTemplate>
</asp:UpdatePanel>
</div>

<div id="divImages" style="position:absolute;z-index:3;background-color:#ffffef;display:none;text-align:center">
<asp:UpdatePanel ID="UpdatePanel2" runat="server">
    <ContentTemplate>
        <iframe src="uploadImage.aspx" id="file" style="width:99%;height:400px;"></iframe>
    </ContentTemplate>    
</asp:UpdatePanel>
</div>

<div id="divAttach" style="position:absolute;z-index:3;background-color:#ffffef;display:none;text-align:center">
<asp:UpdatePanel ID="updatepanel3" runat="server">
    <ContentTemplate>
        <iframe src="uploadAttach.aspx" id="file" style="width:98%;height:400px;"></iframe>
    </ContentTemplate>
</asp:UpdatePanel>
</div>

<div id="divPR" style="position:absolute;z-index:3;background-color:#ffffef;display:none;text-align:center">
<asp:UpdatePanel ID="updatepanel4" runat="server">
    <ContentTemplate>
        <uc3:UCSelectPR ID="UCSelectPR1" runat="server" />
    </ContentTemplate>
</asp:UpdatePanel>
</div>


</asp:Content>
